package com.tarena.lbs.coupon.controller;

import com.tarena.lbs.base.protocol.exception.BusinessException;
import com.tarena.lbs.base.protocol.model.Result;
import com.tarena.lbs.base.protocol.pager.PageResult;
import com.tarena.lbs.coupon.api.pojo.param.UserCouponsParam;
import com.tarena.lbs.coupon.pojo.param.CouponParam;
import com.tarena.lbs.coupon.pojo.query.UserCouponCodeQuery;
import com.tarena.lbs.coupon.pojo.query.UserCouponQuery;
import com.tarena.lbs.coupon.pojo.vo.CouponVO;
import com.tarena.lbs.coupon.pojo.vo.UserCouponsVO;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.*;

/**
 * 处理和优惠券数据业务有关的接口
 */
@RestController
@Slf4j
@Tag(name="优惠券模块")
public class CouponController {


    @Operation(summary = "查询当前商家优惠券分页列表")
    @PostMapping("/admin/marketing/coupon/info/list")
    public Result<PageResult<CouponVO>> pageList() throws BusinessException{
        return null;
    }


    @Operation(summary = "新增优惠券")
    @PostMapping("/admin/marketing/coupon/info/save")
    public Result<Void> addCoupon(@RequestBody CouponParam couponParam)throws BusinessException{
        return null;
    }

    @Operation(summary = "查询优惠券详情")
    @GetMapping("/admin/marketing/coupon/info/detail/{id}")
    public Result<CouponVO> detail(@PathVariable("id") Integer id)
        throws BusinessException{
        return null;
    }



    @Operation(summary = "领取优惠券")
    @PostMapping("/marketing/user/receive/save")
    public Result<Void> receiveCoupon(@RequestBody UserCouponsParam param)
        throws BusinessException{
        return null;
    }


    @Operation(summary = "用户领取优惠券列表")
    @PostMapping("/marketing/user/receive/list")
    public Result<PageResult<UserCouponsVO>> receiveList(@RequestBody UserCouponQuery couponQuery)throws BusinessException{
        return null;
    }


    @Operation(summary = "查看优惠券码的二维码图片")
    @PostMapping("/marketing/user/receive/detail")
    public Result<UserCouponsVO> receiveDetail(@RequestBody UserCouponCodeQuery query)
        throws BusinessException{
        return null;
    }


}
